// 内容头部点击选项卡效果
var h6s = document.querySelectorAll("h6");
var imgs = document.querySelectorAll(".banner>.picture>img")
var span = document.querySelector("span");
var dets = document.querySelectorAll(".detail");
console.log(span)
for (let j = 0; j < h6s.length; j++){
    h6s[j].onclick = function () {
        console.log(1)
        for (var i = 0; i < h6s.length; i++){
            h6s[i].className = "";
            imgs[i].className = "";
            dets[i].className = "detail";
        }
        this.className = "active";
        span.innerText=this.firstElementChild.innerText
        imgs[j].className = "active";
        dets[j].className = " detail active";
        
    }
}
// 新闻中心新闻点击跳转三级网页效果
// var mini = document.querySelectorAll(".mini");
var content = document.querySelector(".content");
console.log(content)
var news = content.firstElementChild.lastElementChild.previousElementSibling;
console.log(news);
news.onclick = e => {
    e = window.event;
    var target = e.srcElement;
 open("news.html","_blank")
    
}


